package com.xw.childhealth.service.impl;

import com.xw.childhealth.dao.ChildrenStandardDao;
import com.xw.childhealth.entity.ChildrenStandard;
import com.xw.childhealth.service.ChildrenStandardService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Description:
 * @Author: y
 * @CreateDate: 2019-11-14 10:18
 * @Version: 1.0
 */
@Service
public class ChildrenStandardServiceImpl implements ChildrenStandardService {

    @Autowired
    private ChildrenStandardDao childrenStandardDao;


    @Override
    public List<ChildrenStandard> findByParentIdEquals(Integer id) {
        return childrenStandardDao.findByParentIdEquals(id);
    }

    @Override
    public ChildrenStandard findByIdEquals(Integer id) {
        return childrenStandardDao.findByIdEquals(id);
    }

    @Override
    public ChildrenStandard save(ChildrenStandard childrenStandard) {
        return childrenStandardDao.save(childrenStandard);
    }

    @Override
    public void delRecord(Integer id) {
        childrenStandardDao.deleteById(id);
    }
}
